import { post,get,put } from '@/util/service'

export const loginApi=data=>{ 
    return post({
        url:"/api/user/login",
        data
    })
}
export const regApi=data=>{ 
    return post({
        url:"/api/user/register",
        data
    })
}
export const userInfoApi=data=>{ 
    return get({
        url:"/api/user/getUser",
        data
    })
}
export const outApi=data=>{ 
    return post({
        url:"/api/user/loginOut",
        data
    })
}

export const uploadApi=data=>{ 
    return post({
        url:"/api/user/uploadAvatar",
        data
    })
}
export const saveApi=data=>{ 
    return put({
        url:"/api/user/updateUser",
        data
    })
}